
from jenkins import Jenkins

class JenkinsContest:

    def __init__(self):
        self.remote_jenkins_url = "http://10.10.10.73:6097/"
        self.jenkins_url = "http://127.0.0.1:6097/"
        self.server = Jenkins(self.jenkins_url, username='yangliang', password='mylove')

        self.result_job = self.server.get_jobs()
        self.job_name = self.result_job[-2]["name"]
        self.job_url = self.server.get_job_info(self.job_name)['url']
        self.job_last_number = self.server.get_job_info(self.job_name)['lastBuild']['number']
        self.report_url = self.job_url + str(self.job_last_number) + '/allure'













